Introduction to Div PHP Template Engine

Div is a [template] engine and [code generator tool] written in PHP and developed since 2011, that allows the separation of labor between developers and designers, and improve the software development based on [Generative Programming], [Model Driven Architecture] and [Meta programming].

As the designer or developer built templates with some specific tags, other developers or designers uses the template to replace these tags with data or more template code. Div have a compact, flexible and descriptive syntax for templates:

  • "compact" means "a minimum of code for template language"
  • "flexible" means "you can create dialects of template language"
  • "descriptive" means "template language talk by herself"

This project is the main piece of the organization Div Software Solutions, following the philosophy of "build more with less" and "divide the problem and not to the people". To obtain this goal, Div propose the [code generation based on templates], following this rules:

  1. The model will have all information about "what do you want to do"
  2. The templates will have all information about "what results you expect"
  3. The engine if the black-box that achieve the "how to make it".

Then, exists these basics operations:

  • Operation #1. Compile a template with models and save the result
  • Operation #2. Transform a model to another, reusing Operation #1.
  • Operation #3. Compose different results, using the engine and other tools.

When you have white these rules, then you will be able to use your imagination and you will be able to achieve the following results, and any combination of them:

  1. Avoid repetitive tasks in the programming
  2. Save your models and reuse them in another project
  3. Scaling your project based in your models.
  4. Migrate your project to different technology
  5. Take advantage of your models and develop parallel versions
  6. Expand your application in other platforms and devices
  7. Improve the performance of your application
  8. Make a documentation of your work
  9. Involve the "non technician" people in the development of the project